from django import forms

from .models import InterviewContent, Interview


class InterviewForm(forms.ModelForm):

    def __init__(self, *args, **kwargs):
        super(InterviewForm, self).__init__(*args, **kwargs)

    class Meta:
        model = Interview
        fields = ('title', 'interviewee', 'interviewer', )
        widgets = {
            'interviewee': forms.widgets.Select(
                attrs={'readonly': True}),
            'interviewer': forms.widgets.Select(
                attrs={'readonly': True}),
        }


class InterviewFinishForm(forms.ModelForm):

    class Meta:
        model = Interview
        fields = ('summary', )


class InterviewContentForm(forms.ModelForm):

    class Meta:
        model = InterviewContent
        fields = ('question',)
